package com.qpkj.oms.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.qpkj.common.annotation.Excel;
import com.qpkj.common.core.domain.BaseEntity;

import javax.validation.constraints.NotBlank;
import java.util.Date;

/**
 * 合同信息对象 oms_contract
 * 
 * @author 光永
 * @date 2023-02-18
 */
public class OmsContract extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 合同id */
    private Long id;

    /** 合同编号 */
    @NotBlank(message = "合同编号不能为空")
    private String contractNo;

    /** 合同名称 */
    @NotBlank(message = "合同名称不能为空")
    private String contractName;

    /** 合同内容 */
    @Excel(name = "合同内容")
    private String contractContent;

    /** 公司名称 */
    @Excel(name = "公司名称")
    private String companyName;

    /** 客户名称 */
    @Excel(name = "客户名称")
    private String customerName;
    /** 文件地址 */
    @Excel(name = "合同附件")
    private String contractUrl;
    /**
     *下单时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "下单时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date placeAnOrderTime;
    /**
     *交货时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "交货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date deliveryTime;

    public Date getPlaceAnOrderTime() {
        return placeAnOrderTime;
    }

    public void setPlaceAnOrderTime(Date placeAnOrderTime) {
        this.placeAnOrderTime = placeAnOrderTime;
    }

    public Date getDeliveryTime() {
        return deliveryTime;
    }

    public void setDeliveryTime(Date deliveryTime) {
        this.deliveryTime = deliveryTime;
    }

    public String getContractUrl() {
        return contractUrl;
    }

    public void setContractUrl(String contractUrl) {
        this.contractUrl = contractUrl;
    }

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setContractNo(String contractNo) 
    {
        this.contractNo = contractNo;
    }

    public String getContractNo() 
    {
        return contractNo;
    }
    public void setContractName(String contractName) 
    {
        this.contractName = contractName;
    }

    public String getContractName() 
    {
        return contractName;
    }
    public void setContractContent(String contractContent) 
    {
        this.contractContent = contractContent;
    }

    public String getContractContent() 
    {
        return contractContent;
    }
    public void setCompanyName(String companyName) 
    {
        this.companyName = companyName;
    }

    public String getCompanyName() 
    {
        return companyName;
    }
    public void setCustomerName(String customerName) 
    {
        this.customerName = customerName;
    }

    public String getCustomerName() 
    {
        return customerName;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("contractNo", getContractNo())
            .append("contractName", getContractName())
            .append("contractContent", getContractContent())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("companyName", getCompanyName())
            .append("customerName", getCustomerName())
                .append("contractUrl", getContractUrl())
                .append("placeAnOrderTime",getPlaceAnOrderTime())
                .append("deliveryTime",getDeliveryTime())
            .toString();
    }
}
